package PrjGNSS

import (
	"fmt"
	"gitee.com/ymofen/supervalue"
)

type CasterMountPointPojo struct {
	Id      string
	sn      int
	show    bool
	srcType int
	srcText string
	Conf    *wrapper.SuperValue
}

/*
*
排序比较
*/
func (this *CasterMountPointPojo) LessCompareTo(obj *CasterMountPointPojo) bool {
	if this.sn != obj.sn {
		return this.sn < obj.sn
	}

	if this.Id != obj.Id {
		return this.Id < obj.Id
	}

	return false
}

func (this *CasterMountPointPojo) GetSrcText() string {
	if len(this.srcText) > 0 {
		return this.srcText + "\r\n"
	} else {
		return fmt.Sprintf("STR;%s;%s;UNKOWN;UNKOWN;0;UNKOWN;misc;CHN;0;0;1;1;;none;B;N;0;;;\r\n", this.Id, this.Id)
	}
}

func (this *CasterMountPointPojo) GetSrcType() int {
	return this.srcType
}
